* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: Arial, sans-serif;
    line-height: 1.6;
    background-color: #f4f4f4;
    opacity: 0;
    animation: fadeIn 0.5s ease-in forwards;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

nav {
    background-color: #333;
    padding: 1rem;
    background: linear-gradient(45deg, #333, #444);
}

nav ul {
    list-style: none;
    display: flex;
    gap: 2rem;
}

nav a {
    color: white;
    text-decoration: none;
    padding: 0.5rem 1rem;
    position: relative;
    overflow: hidden;
}

nav a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background-color: #4CAF50;
    transition: width 0.3s ease;
}

nav a:hover::after {
    width: 100%;
}

nav a.active {
    background-color: #555;
    border-radius: 4px;
}

main {
    padding: 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.dashboard {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
    background-image: url('../images/dashboard-bg.jpg');
    background-size: cover;
    background-position: center;
    padding: 2rem;
    border-radius: 12px;
}

.card {
    background-color: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
    transition: transform 0.3s ease;
}

table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 2rem;
    background-color: white;
}

th, td {
    padding: 1rem;
    text-align: left;
    border-bottom: 1px solid #ddd;
}

th {
    background-color: #f8f8f8;
}

.controls {
    margin: 1rem 0;
    display: flex;
    gap: 1rem;
}

button {
    padding: 0.5rem 1rem;
    background-color: #4CAF50;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

button::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background-color: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: width 0.3s ease, height 0.3s ease;
}

button:hover::after {
    width: 200px;
    height: 200px;
}

button:hover {
    background-color: #45a049;
}

input, select {
    padding: 0.5rem;
    border: 1px solid #ddd;
    border-radius: 4px;
}

.card {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.card-icon {
    font-size: 2.5rem;
    color: #4CAF50;
}

.card-content {
    flex: 1;
}

.btn-edit, .btn-delete {
    padding: 0.3rem 0.6rem;
    margin: 0 0.2rem;
}

.btn-edit {
    background-color: #2196F3;
}

.btn-delete {
    background-color: #f44336;
}

.filter-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.filter-item i {
    color: #666;
}

.card:hover {
    transform: translateY(-5px);
}

.btn-edit:hover {
    background-color: #1976D2;
}

.btn-delete:hover {
    background-color: #D32F2F;
}

nav {
    display: flex;
    align-items: center;
}

nav::before {
    content: "\f0c0";
    font-family: "Font Awesome 6 Free";
    font-weight: 900;
    font-size: 1.5rem;
    color: white;
    margin-right: 1rem;
}

.status-normal {
    color: #4CAF50;
}

.status-late {
    color: #FF9800;
}

.status-absent {
    color: #f44336;
}

.logo {
    height: 40px;
    margin-right: 1rem;
}

.department-icon {
    width: 24px;
    height: 24px;
    vertical-align: middle;
    margin-right: 0.5rem;
}

.employee-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    margin-right: 0.5rem;
    vertical-align: middle;
    object-fit: cover;
}

tr {
    transition: all 0.3s ease;
}

tr:hover {
    background-color: rgba(76, 175, 80, 0.05);
    transform: scale(1.01);
}

.overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.5);
    display: none;
    z-index: 999;
}

.modal {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: white;
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    display: none;
}

.modal.active,
.overlay.active {
    display: block;
}

.department-badge {
    display: inline-flex;
    align-items: center;
    padding: 0.3rem 0.6rem;
    background-color: rgba(76, 175, 80, 0.1);
    border-radius: 4px;
    transition: all 0.3s ease;
}

.department-badge:hover {
    background-color: rgba(76, 175, 80, 0.2);
}

.department-badge img {
    margin-right: 0.5rem;
}

.status-badge.early-leave {
    background-color: rgba(156, 39, 176, 0.1);
    color: #9C27B0;
    padding: 0.3rem 0.6rem;
    border-radius: 4px;
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
}

/* 校园图片展示样式 */
.campus-gallery {
    padding: 2rem;
    background: #f8f9fa;
    margin-top: 2rem;
}

.gallery-title {
    text-align: center;
    color: #1a237e;
    margin-bottom: 2rem;
    font-size: 2rem;
}

.campus-images {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
    padding: 1rem;
}

.campus-image {
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    transition: transform 0.3s ease;
    aspect-ratio: 16/9;
}

.campus-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.campus-image:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 15px rgba(0,0,0,0.2);
}

.campus-image:hover img {
    transform: scale(1.1);
}

.image-caption {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 1rem;
    background: rgba(0,0,0,0.7);
    color: white;
    text-align: center;
    transform: translateY(100%);
    transition: transform 0.3s ease;
    font-size: 1.1rem;
}

.campus-image:hover .image-caption {
    transform: translateY(0);
}

/* 添加响应式布局 */
@media (max-width: 768px) {
    .campus-images {
        grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    }
}

/* 添加图片加载动画 */
@keyframes imageLoading {
    0% { opacity: 0; }
    100% { opacity: 1; }
}

.campus-image img {
    animation: imageLoading 0.5s ease-in;
}

/* 学校 Logo 样式 */
.school-logo {
    width: 120px;
    height: auto;
    margin-bottom: 1.5rem;
    transition: transform 0.3s ease;
}

.school-logo:hover {
    transform: scale(1.1);
}

/* 英雄区域样式 */
.hero-section {
    background-image: linear-gradient(rgba(255, 255, 255, 0.9), rgba(255, 255, 255, 0.9));
    padding: 3rem 0;
    text-align: center;
    margin-bottom: 2rem;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.school-name {
    font-size: 2.5rem;
    color: #1a237e;
    margin: 1.5rem 0;
    font-weight: bold;
}

.school-motto {
    color: #666;
    font-size: 1.2rem;
    font-style: italic;
    margin-bottom: 1.5rem;
}

/* 校徽样式 */
.school-badge {
    width: 150px;  /* 校徽大小 */
    height: auto;
    margin-bottom: 2rem;
    transition: transform 0.3s ease;
    display: block;
    margin-left: auto;
    margin-right: auto;
    object-fit: contain;  /* 保持图片比例 */
}

.school-badge:hover {
    transform: scale(1.1);
}
 